package com.erlang4j.internal.messages;

import com.ericsson.otp.erlang.OtpErlangObject;
import com.erlang4j.api.IBinding;

/**
 * This rips data out of an Erlang object
 * <p>
 * Example<br>
 * &nbsp;&nbsp;&nbsp;binding = parser.parse(object, "{Pid,{command,Param}}", initialBinding);
 * </p>
 * This will either return an invalid binding, or one in which the string "Pid" matches a pid in the object, and "Param"
 * matches the Param in the object </p>
 * 
 * @author Phil Rice
 */
public interface IMessageParser {
	IBinding parse(OtpErlangObject object, String pattern);

	IBinding parse(OtpErlangObject object, String pattern, IBinding binding);

}
